/*
 * @Author: 13938960424 1758142861@qq.com
 * @Date: 2023-10-27 16:16:49
 * @LastEditors: 13938960424 1758142861@qq.com
 * @LastEditTime: 2023-11-05 17:38:49
 * @FilePath: /sjf/new-xshell/muduo/test/client.cc
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */

#include "../server/muduo_server.hpp"
//#include "../server/m.hpp"

int main()
{
    Socket cli_socket;
    // cli_socket.CreateClient(8500,"127.0.0.1");
    cli_socket.CreateClient("127.0.0.1",8500);
    for(int i = 0; i < 5; i++)
    {
        std::string str = "hello";
        cli_socket.Send(str.c_str(),str.size());
        char buff[1024] = {0};
        cli_socket.Recv(buff,1023);
        std::cout << buff << std::endl;
        sleep(1);
    }
    while(1) sleep(1);
    return 0;
}
